<!DOCTYPE html>
<html class="wf-lato-n3-active wf-lato-n4-active wf-lato-n7-active wf-lato-n9-active wf-raleway-n2-active wf-raleway-n3-active wf-raleway-n6-active wf-raleway-n7-active wf-active" lang="en">
<head>
  <!-- META -->

<link rel="stylesheet" type="text/css" href="css/site.css?af5223a75bfbbb15c457d4c7536fd79f">
<script src="js/vendor/jquery.min.js"></script>
  <div class='page-width page-content' id='ContentContainer' role='main'>
    <link rel="stylesheet" href="css/vendor/jquery.contextMenu.css">
<script src="js/vendor/jquery.ui.position.js"></script>
<script src="js/vendor/jquery.contextMenu.js"></script>
 <script>
 var captureKeys = false;
 var keyElement;

$( document ).ready(function() {
   $(".o").click(function(e){  
    keyElement = this; 
    captureKeys = true;
   });

   $( document ).keydown(function(e) {
    console.log(captureKeys);
    if (captureKeys)
    {
      e.preventDefault();
      console.log(e.which);
    }
   });
});


 </script>
<script type="text/javascript">
  var ns = "http://www.w3.org/2000/svg";
  var codeData = [["_T","&empty;","0x00",[0]],["_TEENSY","[Teensy]","0x00",[0]],["_LAYER_0","[L0]","0x00",[0]],["KEY_a_A","a_A","0x04",[65]],["KEY_b_B","b_B","0x05",[66]],["KEY_c_C","c_C","0x06",[67]],["KEY_d_D","d_D","0x07",[68]],["KEY_e_E","e_E","0x08",[69]],["KEY_f_F","f_F","0x09",[70]],["KEY_g_G","g_G","0x0A",[71]],["KEY_h_H","h_H","0x0B",[72]],["KEY_i_I","i_I","0x0C",[73]],["KEY_j_J","j_J","0x0D",[74]],["KEY_k_K","k_K","0x0E",[75]],["KEY_l_L","l_L","0x0F",[76]],["KEY_m_M","m_M","0x10",[77]],["KEY_n_N","n_N","0x11",[78]],["KEY_o_O","o_O","0x12",[79]],["KEY_p_P","p_P","0x13",[80]],["KEY_q_Q","q_Q","0x14",[81]],["KEY_r_R","r_R","0x15",[82]],["KEY_s_S","s_S","0x16",[83]],["KEY_t_T","t_T","0x17",[84]],["KEY_u_U","u_U","0x18",[85]],["KEY_v_V","v_V","0x19",[86]],["KEY_w_W","w_W","0x1A",[87]],["KEY_x_X","x_X","0x1B",[88]],["KEY_y_Y","y_Y","0x1C",[89]],["KEY_z_Z","z_Z","0x1D",[90]],["KEY_1_Exclamation","1_!","0x1E",[49]],["KEY_2_At","2_@","0x1F",[50]],["KEY_3_Pound","3_#","0x20",[51]],["KEY_4_Dollar","4_$","0x21",[52]],["KEY_5_Percent","5_%","0x22",[53]],["KEY_6_Caret","6_^","0x23",[54]],["KEY_7_Ampersand","7_&","0x24",[55]],["KEY_8_Asterisk","8_*","0x25",[56]],["KEY_9_LeftParenthesis","9_(","0x26",[57]],["KEY_0_RightParenthesis","0_)","0x27",[48]],["KEY_ReturnEnter","&crarr;","0x28",[13]],["KEY_Escape","[Esc]","0x29",[27]],["KEY_DeleteBackspace","[Bkspc]","0x2A",[8]],["KEY_Tab","[Tab]","0x2B",[9]],["KEY_Spacebar","[Space]","0x2C",[32]],["KEY_Dash_Underscore","-_&#95;","0x2D",[109,189]],["KEY_Equal_Plus","=_+","0x2E",[61,187]],["KEY_LeftBracket_LeftBrace","[_{","0x2F",[219]],["KEY_RightBracket_RightBrace","]_}","0x30",[221]],["KEY_Backslash_Pipe","\\_|","0x31",[220]],["KEY_Semicolon_Colon",";_:","0x33",[59,186]],["KEY_SingleQuote_DoubleQuote","'_\"","0x34",[222]],["KEY_GraveAccent_Tilde","`_~","0x35",[192]],["KEY_Comma_LessThan",",_<","0x36",[188]],["KEY_Period_GreaterThan","._>","0x37",[190]],["KEY_Slash_Question","\/_?","0x38",[191]],["KEY_F1","F1","0x3A",[112]],["KEY_F2","F2","0x3B",[113]],["KEY_F3","F3","0x3C",[114]],["KEY_F4","F4","0x3D",[115]],["KEY_F5","F5","0x3E",[116]],["KEY_F6","F6","0x3F",[117]],["KEY_F7","F7","0x40",[118]],["KEY_F8","F8","0x41",[119]],["KEY_F9","F9","0x42",[120]],["KEY_F10","F10","0x43",[121]],["KEY_F11","F11","0x44",[122]],["KEY_F12","F12","0x45",[123]],["KEY_Insert","[Ins]","0x49",[45]],["KEY_Home","[Home]","0x4A",[36]],["KEY_PageUp","[PgUp]","0x4B",[33]],["KEY_DeleteForward","[Del]","0x4C",[46]],["KEY_End","[End]","0x4D",[35]],["KEY_PageDown","[PgDn]","0x4E",[34]],["KEY_RightArrow","&rarr;","0x4F",[39]],["KEY_LeftArrow","&larr;","0x50",[37]],["KEY_DownArrow","&darr;","0x51",[40]],["KEY_UpArrow","&uarr;","0x52",[38]],["KEYPAD_NumLock_Clear","[NumLk]","0x53",[144]],["KEYPAD_Slash","\/","0x54",[111]],["KEYPAD_Asterisk","*","0x55",[106]],["KEYPAD_Minus","-","0x56",[109]],["KEYPAD_Plus","+","0x57",[107]],["KEYPAD_ENTER","[Enter]","0x58",[13]],["KEYPAD_1_End","1_[End]","0x59",[97]],["KEYPAD_2_DownArrow","2_&darr;","0x5A",[98]],["KEYPAD_3_PageDown","3_[PgDn]","0x5B",[99]],["KEYPAD_4_LeftArrow","4_&larr;","0x5C",[100]],["KEYPAD_5","5","0x5D",[101]],["KEYPAD_6_RightArrow","6_&rarr;","0x5E",[102]],["KEYPAD_7_Home","7_[Home]","0x5F",[103]],["KEYPAD_8_UpArrow","8_&uarr;","0x60",[104]],["KEYPAD_9_PageUp","9_[PgUp]","0x61",[105]],["KEYPAD_0_Insert","0_[Ins]","0x62",[96]],["KEYPAD_Period_Delete","._[Del]","0x63",[110]],["KEY_LeftControl","[LCtrl]","0xE0",[17]],["KEY_LeftShift","[LShift]","0xE1",[16]],["KEY_LeftAlt","[LAlt]","0xE2",[18]],["KEY_LeftGUI","[LGui]","0xE3",[91]],["KEY_RightControl","[RCtrl]","0xE4",[17]],["KEY_RightShift","[RShift]","0xE5",[16]],["KEY_RightAlt","[RAlt]","0xE6",[18]],["KEY_RightGUI","[RGui]","0xE7",[92]],["_LAYER_TOGGLE_1","[~L1]","0x00",[0]],["_LAYER_TOGGLE_2","[~L2]","0x00",[0]],["_LAYER_TOGGLE_3","[~L3]","0x00",[0]],["_LAYER_TOGGLE_4","[~L4]","0x00",[0]],["_LAYER_TOGGLE_5","[~L5]","0x00",[0]],["_LAYER_TOGGLE_6","[~L6]","0x00",[0]],["_LAYER_TOGGLE_7","[~L7]","0x00",[0]],["_LAYER_TOGGLE_8","[~L8]","0x00",[0]],["_LAYER_TOGGLE_9","[~L9]","0x00",[0]],["_LAYER_PUSH_1","[+L1]","0x00",[0]],["_LAYER_PUSH_2","[+L2]","0x00",[0]],["_LAYER_PUSH_3","[+L3]","0x00",[0]],["_LAYER_PUSH_4","[+L4]","0x00",[0]],["_LAYER_PUSH_5","[+L5]","0x00",[0]],["_LAYER_PUSH_6","[+L6]","0x00",[0]],["_LAYER_PUSH_7","[+L7]","0x00",[0]],["_LAYER_PUSH_8","[+L8]","0x00",[0]],["_LAYER_PUSH_9","[+L9]","0x00",[0]],["_LAYER_POP_1","[-L1]","0x00",[0]],["_LAYER_POP_2","[-L2]","0x00",[0]],["_LAYER_POP_3","[-L3]","0x00",[0]],["_LAYER_POP_4","[-L4]","0x00",[0]],["_LAYER_POP_5","[-L5]","0x00",[0]],["_LAYER_POP_6","[-L6]","0x00",[0]],["_LAYER_POP_7","[-L7]","0x00",[0]],["_LAYER_POP_8","[-L8]","0x00",[0]],["_LAYER_POP_9","[-L9]","0x00",[0]],["KEY_PrintScreen","[PrtSc]","0x46",[0]],["KEY_CapsLock","[CapsLk]","0x39",[20]],["KEY_ScrollLock","[ScrLk]","0x47",[145]],["KEY_Pause","[Pause]","0x48",[19]],["KEY_NonUS_Backslash_Pipe","\\_|","0x64",[0]],["KEY_NonUS_Pound_Tilde","#_~","0x32",[0]],["KEY_Application","[App]","0x65",[0]],["KEY_Power","[Pow]","0x66",[0]],["KEY_Execute","[Exec]","0x74",[0]],["KEY_Help","[Help]","0x75",[0]],["KEY_Menu","[Menu]","0x76",[0]],["KEY_Select","[Select]","0x77",[0]],["KEY_Stop","[Stop]","0x78",[0]],["KEY_Again","[Again]","0x79",[0]],["KEY_Undo","[Undo]","0x7A",[0]],["KEY_Cut","[Cut]","0x7B",[0]],["KEY_Copy","[Copy]","0x7C",[0]],["KEY_Paste","[Paste]","0x7D",[0]],["KEY_Find","[Find]","0x7E",[0]],["KEY_Mute","[Mute]","0x7F",[0]],["KEY_VolumeUp","[Vol+]","0x80",[0]],["KEY_VolumeDown","[Vol-]","0x81",[0]],["KEY_F13","F13","0x68",[0]],["KEY_F14","F14","0x69",[0]],["KEY_F15","F15","0x6A",[0]],["KEY_F16","F16","0x6B",[0]],["KEY_F17","F17","0x6C",[0]],["KEY_F18","F18","0x6D",[0]],["KEY_F19","F19","0x6E",[0]],["KEY_F20","F20","0x6F",[0]],["KEY_F21","F21","0x70",[0]],["KEY_F22","F22","0x71",[0]],["KEY_F23","F23","0x72",[0]],["KEY_F24","F24","0x73",[0]],["_SHIFTED_Underscore","&#95;","0x2D",[0]],["_SHIFTED_Plus","+","0x2E",[0]],["_SHIFTED_LeftBrace","{","0x2F",[0]],["_SHIFTED_RightBrace","}","0x30",[0]],["_SHIFTED_Pipe","|","0x31",[0]],["_SHIFTED_Colon",":","0x33",[0]],["_SHIFTED_DoubleQuote","\"","0x34",[0]],["_SHIFTED_Tilde","~","0x35",[0]],["_SHIFTED_LessThan","<","0x36",[0]],["_SHIFTED_GreaterThan",">","0x37",[0]],["_SHIFTED_Question","?","0x38",[0]],["KEYPAD_Equal","=","0x67",[0]],["KEYPAD_Comma",",","0x85",[0]],["KEYPAD_EqualSign","=","0x86",[0]],["KEYPAD_00","00","0xB0",[0]],["KEYPAD_000","000","0xB1",[0]],["KEY_ThousandsSeparator","[1000Sep]","0xB2",[0]],["KEY_DecimalSeparator","[DecSep]","0xB3",[0]],["KEY_CurrencyUnit","[CurUnit]","0xB4",[0]],["KEY_CurrencySubunit","[CurSub]","0xB5",[0]],["KEYPAD_LeftParenthesis","(","0xB6",[0]],["KEYPAD_RightParenthesis",")","0xB7",[0]],["KEYPAD_LeftBrace","{","0xB8",[0]],["KEYPAD_RightBrace","}","0xB9",[0]],["KEYPAD_Tab","[Tab]","0xBA",[0]],["KEYPAD_Backspace","[Bkspc]","0xBB",[0]],["KEYPAD_A","A","0xBC",[0]],["KEYPAD_B","B","0xBD",[0]],["KEYPAD_C","C","0xBE",[0]],["KEYPAD_D","D","0xBF",[0]],["KEYPAD_E","E","0xC0",[0]],["KEYPAD_F","F","0xC1",[0]],["KEYPAD_XOR","[Xor]","0xC2",[0]],["KEYPAD_Caret","^","0xC3",[0]],["KEYPAD_Percent","%","0xC4",[0]],["KEYPAD_LessThan","<","0xC5",[0]],["KEYPAD_GreaterThan",">","0xC6",[0]],["KEYPAD_Ampersand","&","0xC7",[0]],["KEYPAD_AmpersandAmpersand","&&","0xC8",[0]],["KEYPAD_Pipe","|","0xC9",[0]],["KEYPAD_PipePipe","||","0xCA",[0]],["KEYPAD_Colon",":","0xCB",[0]],["KEYPAD_Pound","#","0xCC",[0]],["KEYPAD_Space","[Space]","0xCD",[0]],["KEYPAD_At","@","0xCE",[0]],["KEYPAD_Exclamation","!","0xCF",[0]],["KEYPAD_MemoryStore","MS","0xD0",[0]],["KEYPAD_MemoryRecall","MR","0xD1",[0]],["KEYPAD_MemoryClear","MC","0xD2",[0]],["KEYPAD_MemoryAdd","M+","0xD3",[0]],["KEYPAD_MemorySubtract","M-","0xD4",[0]],["KEYPAD_MemoryMultiply","M&times;","0xD5",[0]],["KEYPAD_MemoryDivide","M&divide;","0xD6",[0]],["KEYPAD_PlusMinus","&plusmn;","0xD7",[0]],["KEYPAD_Clear","[Clr]","0xD8",[0]],["KEYPAD_ClearEntry","[ClrEntry]","0xD9",[0]],["KEYPAD_Binary","[Bin]","0xDA",[0]],["KEYPAD_Octal","[Oct]","0xDB",[0]],["KEYPAD_Decimal","[Dec]","0xDC",[0]],["KEYPAD_Hexadecimal","[Hex]","0xDD",[0]],["KEY_International1","[Intl1]","0x87",[0]],["KEY_International2","[Intl2]","0x88",[0]],["KEY_International3","[Intl3]","0x89",[0]],["KEY_International4","[Intl4]","0x8A",[0]],["KEY_International5","[Intl5]","0x8B",[0]],["KEY_International6","[Intl6]","0x8C",[0]],["KEY_International7","[Intl7]","0x8D",[0]],["KEY_International8","[Intl8]","0x8E",[0]],["KEY_International9","[Intl9]","0x8F",[0]],["KEY_LANG1","[Lang1]","0x90",[0]],["KEY_LANG2","[Lang2]","0x91",[0]],["KEY_LANG3","[Lang3]","0x92",[0]],["KEY_LANG4","[Lang4]","0x93",[0]],["KEY_LANG5","[Lang5]","0x94",[0]],["KEY_LANG6","[Lang6]","0x95",[0]],["KEY_LANG7","[Lang7]","0x96",[0]],["KEY_LANG8","[Lang8]","0x97",[0]],["KEY_LANG9","[Lang9]","0x98",[0]],["KEY_AlternateErase","[AltErs]","0x99",[0]],["KEY_SysReq_Attention","[SysReq]","0x9A",[0]],["KEY_Cancel","[Cancel]","0x9B",[0]],["KEY_Clear","[Clear]","0x9C",[0]],["KEY_Prior","[Prior]","0x9D",[0]],["KEY_Return","[Return]","0x9E",[0]],["KEY_Separator","[Sep]","0x9F",[0]],["KEY_Out","[Out]","0xA0",[0]],["KEY_Oper","[Oper]","0xA1",[0]],["KEY_Clear_Again","[ClrAgain]","0xA2",[0]],["KEY_CrSel_Props","[CrSel]","0xA3",[0]],["KEY_ExSel","[ExSel]","0xA4",[0]]];
  var layers = new Array();
  var $activeKey = null;

  // initialize layers array (10 layers)
  for (var i = 0; i < 10; i++) {
    layers.push(new Array());
    for (var j = 0; j < 81; j++) layers[i][j] = null;
  }

  // key manipulation
  function get_key_data(kc) {
    var m = codeData.length;
    for (var i = 0; i < m; i++) {
      if ($.inArray(kc, codeData[i][3]) >= 0) return codeData[i];
    }
    return null;
  }
  function get_key_data_by_const(kc) {
    var m = codeData.length;
    for (var i = 0; i < m; i++) {
      if (codeData[i][0] == kc) return codeData[i];
    }
    return null;  
    
  }
  function set_key_text($key, key_data) {
    var node = $key.closest("svg").find(".t-" + $key.data("id"))[0];
    while (node.hasChildNodes()) {
      node.removeChild(node.lastChild);
    }
    if (key_data != null && key_data != "") {
      if (key_data[1].indexOf("_") >= 0) {
        var tmp = key_data[1].split("_");
        var top = document.createElementNS(ns, "tspan");
        var bot = document.createElementNS(ns, "tspan");
        top.textContent = $('<div/>').html(tmp[1]).text();
        bot.textContent = $('<div/>').html(tmp[0]).text();
        top.setAttribute("x", node.getAttribute("x"));
        top.setAttribute("dy", -7);
        bot.setAttribute("x", node.getAttribute("x"));
        bot.setAttribute("dy", +14);
        node.appendChild(top);
        node.appendChild(bot);
      } else {
        node.textContent = $('<div/>').html(key_data[1]).text();
      }
      layers[parseInt($key.closest("svg").data("id"))][parseInt($key.data("id"))] = key_data[0];
    } else {
      layers[parseInt($key.closest("svg").data("id"))][parseInt($key.data("id"))] = null;
    }
  }
  function set_active_key($key, isLClick, initEvent) {
    $activeKey = $key;
    var $key_bg = $key.closest("svg").find(".k-" + $key.data("id"));
    var isKeyAlreadyActive = ($key_bg.attr("style") != "" && $key_bg.attr("style") != null);
    $(document).unbind("keydown");
    $('rect').attr("style", "");
    if (!isKeyAlreadyActive) {
      $key_bg.attr("style", "fill: #fb8800");
      if (isLClick) {
        $(document).one("keydown", function (e) {
          e.preventDefault();
          set_active_key($activeKey, true, null);
          var key_data = get_key_data(e.which);
          if (key_data != null) {
            set_key_text($activeKey, key_data);
          }
        });
      } else {
        if (initEvent != null) $("#svg-container").contextMenu({x:initEvent.pageX, y:initEvent.pageY});
      }
    }
  }

  // some other functions
  function toggleButton($elem, busyText) {
    if (!$elem.hasClass("disabled")) {
      $elem.data("text", $elem.text());
      $elem.addClass("disabled").attr("disabled", "disabled").text(busyText);
    } else {
      $elem.removeClass("disabled").removeAttr("disabled").text($elem.data("text"));
    }
  }
  function loadLayerJson(data) {
    for (var i = 0; i < data.length; i++) {
      var $layer = $('#l-' + i);
      for (var j = 0; j < data[i].length; j++) {
        var $overlay = $layer.find('.o-' + j);
        if ($overlay.length > 0) {
          var key_data = get_key_data_by_const(data[i][j]);
          set_key_text($overlay, key_data);
        }
      }
    }
  }

  // compile templates
  var compiledTemplates = new Array();
  function compile(tplId) {
    if (!compiledTemplates.hasOwnProperty(tplId)) compiledTemplates[tplId] = Handlebars.compile(document.getElementById(tplId).innerHTML);
    return compiledTemplates[tplId];
  }

  // initialization routine
  $(function () {
    // svg events
    $('.o')
      .click(function (e) {
        set_active_key($(this), true, e);
      })
      .on("contextmenu", function (e) {
        e.preventDefault();
        set_active_key($(this), false, e);
      });

    // context menu init (with special events)
    //var contextMenuItems = {"Clear":{"name":"Clear"},"_T":{"name":"_T"},"_TEENSY":{"name":"_TEENSY"},"_LAYER_0":{"name":"_LAYER_0"},"Divider50587":"-","Alphabet":{"name":"Alphabet","items":{"KEY_a_A":{"name":"KEY_a_A"},"KEY_b_B":{"name":"KEY_b_B"},"KEY_c_C":{"name":"KEY_c_C"},"KEY_d_D":{"name":"KEY_d_D"},"KEY_e_E":{"name":"KEY_e_E"},"KEY_f_F":{"name":"KEY_f_F"},"KEY_g_G":{"name":"KEY_g_G"},"KEY_h_H":{"name":"KEY_h_H"},"KEY_i_I":{"name":"KEY_i_I"},"KEY_j_J":{"name":"KEY_j_J"},"KEY_k_K":{"name":"KEY_k_K"},"KEY_l_L":{"name":"KEY_l_L"},"KEY_m_M":{"name":"KEY_m_M"},"KEY_n_N":{"name":"KEY_n_N"},"KEY_o_O":{"name":"KEY_o_O"},"KEY_p_P":{"name":"KEY_p_P"},"KEY_q_Q":{"name":"KEY_q_Q"},"KEY_r_R":{"name":"KEY_r_R"},"KEY_s_S":{"name":"KEY_s_S"},"KEY_t_T":{"name":"KEY_t_T"},"KEY_u_U":{"name":"KEY_u_U"},"KEY_v_V":{"name":"KEY_v_V"},"KEY_w_W":{"name":"KEY_w_W"},"KEY_x_X":{"name":"KEY_x_X"},"KEY_y_Y":{"name":"KEY_y_Y"},"KEY_z_Z":{"name":"KEY_z_Z"}}},"Number Row":{"name":"Number Row","items":{"KEY_1_Exclamation":{"name":"KEY_1_Exclamation"},"KEY_2_At":{"name":"KEY_2_At"},"KEY_3_Pound":{"name":"KEY_3_Pound"},"KEY_4_Dollar":{"name":"KEY_4_Dollar"},"KEY_5_Percent":{"name":"KEY_5_Percent"},"KEY_6_Caret":{"name":"KEY_6_Caret"},"KEY_7_Ampersand":{"name":"KEY_7_Ampersand"},"KEY_8_Asterisk":{"name":"KEY_8_Asterisk"},"KEY_9_LeftParenthesis":{"name":"KEY_9_LeftParenthesis"},"KEY_0_RightParenthesis":{"name":"KEY_0_RightParenthesis"}}},"Spacing":{"name":"Spacing","items":{"KEY_ReturnEnter":{"name":"KEY_ReturnEnter"},"KEY_Escape":{"name":"KEY_Escape"},"KEY_DeleteBackspace":{"name":"KEY_DeleteBackspace"},"KEY_Tab":{"name":"KEY_Tab"},"KEY_Spacebar":{"name":"KEY_Spacebar"}}},"Punctuation":{"name":"Punctuation","items":{"KEY_Dash_Underscore":{"name":"KEY_Dash_Underscore"},"KEY_Equal_Plus":{"name":"KEY_Equal_Plus"},"KEY_LeftBracket_LeftBrace":{"name":"KEY_LeftBracket_LeftBrace"},"KEY_RightBracket_RightBrace":{"name":"KEY_RightBracket_RightBrace"},"KEY_Backslash_Pipe":{"name":"KEY_Backslash_Pipe"},"KEY_Semicolon_Colon":{"name":"KEY_Semicolon_Colon"},"KEY_SingleQuote_DoubleQuote":{"name":"KEY_SingleQuote_DoubleQuote"},"KEY_GraveAccent_Tilde":{"name":"KEY_GraveAccent_Tilde"},"KEY_Comma_LessThan":{"name":"KEY_Comma_LessThan"},"KEY_Period_GreaterThan":{"name":"KEY_Period_GreaterThan"},"KEY_Slash_Question":{"name":"KEY_Slash_Question"}}},"Function Keys (F1-F12)":{"name":"Function Keys (F1-F12)","items":{"KEY_F1":{"name":"KEY_F1"},"KEY_F2":{"name":"KEY_F2"},"KEY_F3":{"name":"KEY_F3"},"KEY_F4":{"name":"KEY_F4"},"KEY_F5":{"name":"KEY_F5"},"KEY_F6":{"name":"KEY_F6"},"KEY_F7":{"name":"KEY_F7"},"KEY_F8":{"name":"KEY_F8"},"KEY_F9":{"name":"KEY_F9"},"KEY_F10":{"name":"KEY_F10"},"KEY_F11":{"name":"KEY_F11"},"KEY_F12":{"name":"KEY_F12"}}},"Navigation":{"name":"Navigation","items":{"KEY_Insert":{"name":"KEY_Insert"},"KEY_Home":{"name":"KEY_Home"},"KEY_PageUp":{"name":"KEY_PageUp"},"KEY_DeleteForward":{"name":"KEY_DeleteForward"},"KEY_End":{"name":"KEY_End"},"KEY_PageDown":{"name":"KEY_PageDown"},"KEY_RightArrow":{"name":"KEY_RightArrow"},"KEY_LeftArrow":{"name":"KEY_LeftArrow"},"KEY_DownArrow":{"name":"KEY_DownArrow"},"KEY_UpArrow":{"name":"KEY_UpArrow"}}},"Number Pad":{"name":"Number Pad","items":{"KEYPAD_NumLock_Clear":{"name":"KEYPAD_NumLock_Clear"},"KEYPAD_Slash":{"name":"KEYPAD_Slash"},"KEYPAD_Asterisk":{"name":"KEYPAD_Asterisk"},"KEYPAD_Minus":{"name":"KEYPAD_Minus"},"KEYPAD_Plus":{"name":"KEYPAD_Plus"},"KEYPAD_ENTER":{"name":"KEYPAD_ENTER"},"KEYPAD_1_End":{"name":"KEYPAD_1_End"},"KEYPAD_2_DownArrow":{"name":"KEYPAD_2_DownArrow"},"KEYPAD_3_PageDown":{"name":"KEYPAD_3_PageDown"},"KEYPAD_4_LeftArrow":{"name":"KEYPAD_4_LeftArrow"},"KEYPAD_5":{"name":"KEYPAD_5"},"KEYPAD_6_RightArrow":{"name":"KEYPAD_6_RightArrow"},"KEYPAD_7_Home":{"name":"KEYPAD_7_Home"},"KEYPAD_8_UpArrow":{"name":"KEYPAD_8_UpArrow"},"KEYPAD_9_PageUp":{"name":"KEYPAD_9_PageUp"},"KEYPAD_0_Insert":{"name":"KEYPAD_0_Insert"},"KEYPAD_Period_Delete":{"name":"KEYPAD_Period_Delete"}}},"Control Keys":{"name":"Control Keys","items":{"KEY_LeftControl":{"name":"KEY_LeftControl"},"KEY_LeftShift":{"name":"KEY_LeftShift"},"KEY_LeftAlt":{"name":"KEY_LeftAlt"},"KEY_LeftGUI":{"name":"KEY_LeftGUI"},"KEY_RightControl":{"name":"KEY_RightControl"},"KEY_RightShift":{"name":"KEY_RightShift"},"KEY_RightAlt":{"name":"KEY_RightAlt"},"KEY_RightGUI":{"name":"KEY_RightGUI"}}},"Divider83698":"-","Toggle Layers":{"name":"Toggle Layers","items":{"_LAYER_TOGGLE_1":{"name":"_LAYER_TOGGLE_1"},"_LAYER_TOGGLE_2":{"name":"_LAYER_TOGGLE_2"},"_LAYER_TOGGLE_3":{"name":"_LAYER_TOGGLE_3"},"_LAYER_TOGGLE_4":{"name":"_LAYER_TOGGLE_4"},"_LAYER_TOGGLE_5":{"name":"_LAYER_TOGGLE_5"},"_LAYER_TOGGLE_6":{"name":"_LAYER_TOGGLE_6"},"_LAYER_TOGGLE_7":{"name":"_LAYER_TOGGLE_7"},"_LAYER_TOGGLE_8":{"name":"_LAYER_TOGGLE_8"},"_LAYER_TOGGLE_9":{"name":"_LAYER_TOGGLE_9"}}},"Push Layers":{"name":"Push Layers","items":{"_LAYER_PUSH_1":{"name":"_LAYER_PUSH_1"},"_LAYER_PUSH_2":{"name":"_LAYER_PUSH_2"},"_LAYER_PUSH_3":{"name":"_LAYER_PUSH_3"},"_LAYER_PUSH_4":{"name":"_LAYER_PUSH_4"},"_LAYER_PUSH_5":{"name":"_LAYER_PUSH_5"},"_LAYER_PUSH_6":{"name":"_LAYER_PUSH_6"},"_LAYER_PUSH_7":{"name":"_LAYER_PUSH_7"},"_LAYER_PUSH_8":{"name":"_LAYER_PUSH_8"},"_LAYER_PUSH_9":{"name":"_LAYER_PUSH_9"}}},"Pop Layers":{"name":"Pop Layers","items":{"_LAYER_POP_1":{"name":"_LAYER_POP_1"},"_LAYER_POP_2":{"name":"_LAYER_POP_2"},"_LAYER_POP_3":{"name":"_LAYER_POP_3"},"_LAYER_POP_4":{"name":"_LAYER_POP_4"},"_LAYER_POP_5":{"name":"_LAYER_POP_5"},"_LAYER_POP_6":{"name":"_LAYER_POP_6"},"_LAYER_POP_7":{"name":"_LAYER_POP_7"},"_LAYER_POP_8":{"name":"_LAYER_POP_8"},"_LAYER_POP_9":{"name":"_LAYER_POP_9"}}},"Divider68513":"-","Misc":{"name":"Misc","items":{"KEY_PrintScreen":{"name":"KEY_PrintScreen"},"KEY_CapsLock":{"name":"KEY_CapsLock"},"KEY_ScrollLock":{"name":"KEY_ScrollLock"},"KEY_Pause":{"name":"KEY_Pause"},"KEY_NonUS_Backslash_Pipe":{"name":"KEY_NonUS_Backslash_Pipe"},"KEY_NonUS_Pound_Tilde":{"name":"KEY_NonUS_Pound_Tilde"}}},"Media Keys":{"name":"Media Keys","items":{"KEY_Application":{"name":"KEY_Application"},"KEY_Power":{"name":"KEY_Power"},"KEY_Execute":{"name":"KEY_Execute"},"KEY_Help":{"name":"KEY_Help"},"KEY_Menu":{"name":"KEY_Menu"},"KEY_Select":{"name":"KEY_Select"},"KEY_Stop":{"name":"KEY_Stop"},"KEY_Again":{"name":"KEY_Again"},"KEY_Undo":{"name":"KEY_Undo"},"KEY_Cut":{"name":"KEY_Cut"},"KEY_Copy":{"name":"KEY_Copy"},"KEY_Paste":{"name":"KEY_Paste"},"KEY_Find":{"name":"KEY_Find"},"KEY_Mute":{"name":"KEY_Mute"},"KEY_VolumeUp":{"name":"KEY_VolumeUp"},"KEY_VolumeDown":{"name":"KEY_VolumeDown"}}},"Function Keys (F13-F24)":{"name":"Function Keys (F13-F24)","items":{"KEY_F13":{"name":"KEY_F13"},"KEY_F14":{"name":"KEY_F14"},"KEY_F15":{"name":"KEY_F15"},"KEY_F16":{"name":"KEY_F16"},"KEY_F17":{"name":"KEY_F17"},"KEY_F18":{"name":"KEY_F18"},"KEY_F19":{"name":"KEY_F19"},"KEY_F20":{"name":"KEY_F20"},"KEY_F21":{"name":"KEY_F21"},"KEY_F22":{"name":"KEY_F22"},"KEY_F23":{"name":"KEY_F23"},"KEY_F24":{"name":"KEY_F24"}}},"Shifted":{"name":"Shifted","items":{"_SHIFTED_Underscore":{"name":"_SHIFTED_Underscore"},"_SHIFTED_Plus":{"name":"_SHIFTED_Plus"},"_SHIFTED_LeftBrace":{"name":"_SHIFTED_LeftBrace"},"_SHIFTED_RightBrace":{"name":"_SHIFTED_RightBrace"},"_SHIFTED_Pipe":{"name":"_SHIFTED_Pipe"},"_SHIFTED_Colon":{"name":"_SHIFTED_Colon"},"_SHIFTED_DoubleQuote":{"name":"_SHIFTED_DoubleQuote"},"_SHIFTED_Tilde":{"name":"_SHIFTED_Tilde"},"_SHIFTED_LessThan":{"name":"_SHIFTED_LessThan"},"_SHIFTED_GreaterThan":{"name":"_SHIFTED_GreaterThan"},"_SHIFTED_Question":{"name":"_SHIFTED_Question"}}},"Extended Number Pad 1":{"name":"Extended Number Pad 1","items":{"KEYPAD_Equal":{"name":"KEYPAD_Equal"},"KEYPAD_Comma":{"name":"KEYPAD_Comma"},"KEYPAD_EqualSign":{"name":"KEYPAD_EqualSign"},"KEYPAD_00":{"name":"KEYPAD_00"},"KEYPAD_000":{"name":"KEYPAD_000"},"KEY_ThousandsSeparator":{"name":"KEY_ThousandsSeparator"},"KEY_DecimalSeparator":{"name":"KEY_DecimalSeparator"},"KEY_CurrencyUnit":{"name":"KEY_CurrencyUnit"},"KEY_CurrencySubunit":{"name":"KEY_CurrencySubunit"},"KEYPAD_LeftParenthesis":{"name":"KEYPAD_LeftParenthesis"},"KEYPAD_RightParenthesis":{"name":"KEYPAD_RightParenthesis"},"KEYPAD_LeftBrace":{"name":"KEYPAD_LeftBrace"},"KEYPAD_RightBrace":{"name":"KEYPAD_RightBrace"},"KEYPAD_Tab":{"name":"KEYPAD_Tab"},"KEYPAD_Backspace":{"name":"KEYPAD_Backspace"},"KEYPAD_A":{"name":"KEYPAD_A"},"KEYPAD_B":{"name":"KEYPAD_B"},"KEYPAD_C":{"name":"KEYPAD_C"},"KEYPAD_D":{"name":"KEYPAD_D"},"KEYPAD_E":{"name":"KEYPAD_E"},"KEYPAD_F":{"name":"KEYPAD_F"}}},"Extended Number Pad 2":{"name":"Extended Number Pad 2","items":{"KEYPAD_XOR":{"name":"KEYPAD_XOR"},"KEYPAD_Caret":{"name":"KEYPAD_Caret"},"KEYPAD_Percent":{"name":"KEYPAD_Percent"},"KEYPAD_LessThan":{"name":"KEYPAD_LessThan"},"KEYPAD_GreaterThan":{"name":"KEYPAD_GreaterThan"},"KEYPAD_Ampersand":{"name":"KEYPAD_Ampersand"},"KEYPAD_AmpersandAmpersand":{"name":"KEYPAD_AmpersandAmpersand"},"KEYPAD_Pipe":{"name":"KEYPAD_Pipe"},"KEYPAD_PipePipe":{"name":"KEYPAD_PipePipe"},"KEYPAD_Colon":{"name":"KEYPAD_Colon"},"KEYPAD_Pound":{"name":"KEYPAD_Pound"},"KEYPAD_Space":{"name":"KEYPAD_Space"},"KEYPAD_At":{"name":"KEYPAD_At"},"KEYPAD_Exclamation":{"name":"KEYPAD_Exclamation"},"KEYPAD_MemoryStore":{"name":"KEYPAD_MemoryStore"},"KEYPAD_MemoryRecall":{"name":"KEYPAD_MemoryRecall"},"KEYPAD_MemoryClear":{"name":"KEYPAD_MemoryClear"},"KEYPAD_MemoryAdd":{"name":"KEYPAD_MemoryAdd"},"KEYPAD_MemorySubtract":{"name":"KEYPAD_MemorySubtract"},"KEYPAD_MemoryMultiply":{"name":"KEYPAD_MemoryMultiply"},"KEYPAD_MemoryDivide":{"name":"KEYPAD_MemoryDivide"},"KEYPAD_PlusMinus":{"name":"KEYPAD_PlusMinus"},"KEYPAD_Clear":{"name":"KEYPAD_Clear"},"KEYPAD_ClearEntry":{"name":"KEYPAD_ClearEntry"},"KEYPAD_Binary":{"name":"KEYPAD_Binary"},"KEYPAD_Octal":{"name":"KEYPAD_Octal"},"KEYPAD_Decimal":{"name":"KEYPAD_Decimal"},"KEYPAD_Hexadecimal":{"name":"KEYPAD_Hexadecimal"}}},"Unknown":{"name":"Unknown","items":{"KEY_International1":{"name":"KEY_International1"},"KEY_International2":{"name":"KEY_International2"},"KEY_International3":{"name":"KEY_International3"},"KEY_International4":{"name":"KEY_International4"},"KEY_International5":{"name":"KEY_International5"},"KEY_International6":{"name":"KEY_International6"},"KEY_International7":{"name":"KEY_International7"},"KEY_International8":{"name":"KEY_International8"},"KEY_International9":{"name":"KEY_International9"},"KEY_LANG1":{"name":"KEY_LANG1"},"KEY_LANG2":{"name":"KEY_LANG2"},"KEY_LANG3":{"name":"KEY_LANG3"},"KEY_LANG4":{"name":"KEY_LANG4"},"KEY_LANG5":{"name":"KEY_LANG5"},"KEY_LANG6":{"name":"KEY_LANG6"},"KEY_LANG7":{"name":"KEY_LANG7"},"KEY_LANG8":{"name":"KEY_LANG8"},"KEY_LANG9":{"name":"KEY_LANG9"},"KEY_AlternateErase":{"name":"KEY_AlternateErase"},"KEY_SysReq_Attention":{"name":"KEY_SysReq_Attention"},"KEY_Cancel":{"name":"KEY_Cancel"},"KEY_Clear":{"name":"KEY_Clear"},"KEY_Prior":{"name":"KEY_Prior"},"KEY_Return":{"name":"KEY_Return"},"KEY_Separator":{"name":"KEY_Separator"},"KEY_Out":{"name":"KEY_Out"},"KEY_Oper":{"name":"KEY_Oper"},"KEY_Clear_Again":{"name":"KEY_Clear_Again"},"KEY_CrSel_Props":{"name":"KEY_CrSel_Props"},"KEY_ExSel":{"name":"KEY_ExSel"}}}};
    var contextMenuItems = {"Clear":{"name":"Clear"},"KC_NO":{ "name":"KC_NO"},"KC_ROLL_OVER":{"name":"KC_ROLL_OVER"},"KC_POST_FAIL":{"name":"KC_POST_FAIL"},  
     "KC_UNDEFINED":{"name":"KC_UNDEFINED"},   "KC_A":{"name":"KC_A"},   "KC_B":{"name":"KC_B"},   "KC_C":{"name":"KC_C"},   "KC_D":{"name":"KC_D"},
        "KC_E":{"name":"KC_E"},   "KC_F":{"name":"KC_F"},   "KC_G":{"name":"KC_G"},   "KC_H":{"name":"KC_H"},   "KC_I":{"name":"KC_I"},   "KC_J":{"name":"KC_J"}, 
          "KC_K":{"name":"KC_K"},   "KC_L":{"name":"KC_L"},   "KC_M":{"name":"KC_M"},                "KC_N":{"name":"KC_N"},   "KC_O":{"name":"KC_O"},   "KC_P":{"name":"KC_P"}, 
            "KC_Q":{"name":"KC_Q"},   "KC_R":{"name":"KC_R"},   "KC_S":{"name":"KC_S"},   "KC_T":{"name":"KC_T"},   "KC_U":{"name":"KC_U"},   "KC_V":{"name":"KC_V"},   "KC_W":{"name":"KC_W"},   "KC_X":{"name":"KC_X"},   "KC_Y":{"name":"KC_Y"},   "KC_Z":{"name":"KC_Z"},   "KC_1":{"name":"KC_1"},   "KC_2":{"name":"KC_2"},   "KC_3":{"name":"KC_3"},                  "KC_4":{"name":"KC_4"},   "KC_5":{"name":"KC_5"},   "KC_6":{"name":"KC_6"},   "KC_7":{"name":"KC_7"},   "KC_8":{"name":"KC_8"},   "KC_9":{"name":"KC_9"},   "KC_0":{"name":"KC_0"},   "KC_ENTER":{"name":"KC_ENTER"},   "KC_ESCAPE":{"name":"KC_ESCAPE"},   "KC_BSPACE":{"name":"KC_BSPACE"},   "KC_TAB":{"name":"KC_TAB"},   "KC_SPACE":{"name":"KC_SPACE"},   "KC_MINUS":{"name":"KC_MINUS"},   "KC_EQUAL":{"name":"KC_EQUAL"},   "KC_LBRACKET":{"name":"KC_LBRACKET"},   "KC_RBRACKET":{"name":"KC_RBRACKET"},            "KC_BSLASH":{"name":"KC_BSLASH"},              "KC_NONUS_HASH":{"name":"KC_NONUS_HASH"},         "KC_SCOLON":{"name":"KC_SCOLON"},             "KC_QUOTE":{"name":"KC_QUOTE"},    
   "KC_GRAVE":{"name":"KC_GRAVE"},              "KC_COMMA":{"name":"KC_COMMA"},               "KC_DOT":{"name":"KC_DOT"},                "KC_SLASH":{"name":"KC_SLASH"},               "KC_CAPSLOCK":{"name":"KC_CAPSLOCK"},   "KC_F1":{"name":"KC_F1"}, 
     "KC_F2":{"name":"KC_F2"}, "KC_F3" :{ "name" : "KC_F3" },    "KC_F4":{"name":"KC_F4"},  
      "KC_F5":{"name":"KC_F5"},   "KC_F6":{"name":"KC_F6"},   "KC_F7":{"name":"KC_F7"},                  "KC_F8":{"name":"KC_F8"},   "KC_F9":{"name":"KC_F9"},   "KC_F10":{"name":"KC_F10"},   "KC_F11":{"name":"KC_F11"},   "KC_F12":{"name":"KC_F12"},   "KC_PSCREEN":{"name":"KC_PSCREEN"},   "KC_SCROLLLOCK":{"name":"KC_SCROLLLOCK"},   "KC_PAUSE":{"name":"KC_PAUSE"},   "KC_INSERT":{"name":"KC_INSERT"},   "KC_HOME":{"name":"KC_HOME"},   "KC_PGUP":{"name":"KC_PGUP"},   "KC_DELETE":{"name":"KC_DELETE"},   "KC_END":{"name":"KC_END"},   "KC_PGDOWN":{"name":"KC_PGDOWN"}, 
              "KC_RIGHT":{"name":"KC_RIGHT"},   "KC_LEFT":{"name":"KC_LEFT"},                "KC_DOWN":{"name":"KC_DOWN"},   "KC_UP":{"name":"KC_UP"},   "KC_NUMLOCK":{"name":"KC_NUMLOCK"},   "KC_KP_SLASH":{"name":"KC_KP_SLASH"},   "KC_KP_ASTERISK":{"name":"KC_KP_ASTERISK"},   "KC_KP_MINUS":{"name":"KC_KP_MINUS"},   "KC_KP_PLUS":{"name":"KC_KP_PLUS"},   "KC_KP_ENTER":{"name":"KC_KP_ENTER"},   "KC_KP_1":{"name":"KC_KP_1"},   "KC_KP_2":{"name":"KC_KP_2"},   "KC_KP_3":{"name":"KC_KP_3"},   "KC_KP_4":{"name":"KC_KP_4"},   "KC_KP_5":{"name":"KC_KP_5"},   "KC_KP_6":{"name":"KC_KP_6"},   "KC_KP_7":{"name":"KC_KP_7"},   "KC_KP_8":{"name":"KC_KP_8"},                "KC_KP_9":{"name":"KC_KP_9"},   "KC_KP_0":{"name":"KC_KP_0"},   "KC_KP_DOT":{"name":"KC_KP_DOT"},   "KC_NONUS_BSLASH":{"name":"KC_NONUS_BSLASH"},       "KC_APPLICATION":{"name":"KC_APPLICATION"},   "KC_POWER":{"name":"KC_POWER"},   "KC_KP_EQUAL":{"name":"KC_KP_EQUAL"},   "KC_F13":{"name":"KC_F13"},   "KC_F14":{"name":"KC_F14"},   "KC_F15":{"name":"KC_F15"},   "KC_F16":{"name":"KC_F16"},  
             "KC_F17":{"name":"KC_F17"},   "KC_F18":{"name":"KC_F18"},   "KC_F19":{"name":"KC_F19"},   "KC_F20":{"name":"KC_F20"},   "KC_F21":{"name":"KC_F21"},                "KC_F22":{"name":"KC_F22"},   "KC_F23":{"name":"KC_F23"},   "KC_F24":{"name":"KC_F24"},   "KC_EXECUTE":{"name":"KC_EXECUTE"},   "KC_HELP":{"name":"KC_HELP"},   "KC_MENU":{"name":"KC_MENU"},   "KC_SELECT":{"name":"KC_SELECT"},   "KC_STOP":{"name":"KC_STOP"},   "KC_AGAIN":{"name":"KC_AGAIN"},   "KC_UNDO":{"name":"KC_UNDO"},   "KC_CUT":{"name":"KC_CUT"},   "KC_COPY":{"name":"KC_COPY"},   "KC_PASTE":{"name":"KC_PASTE"},   "KC_FIND":{"name":"KC_FIND"},   "KC__MUTE":{"name":"KC__MUTE"},   "KC__VOLUP":{"name":"KC__VOLUP"},             "KC__VOLDOWN":{"name":"KC__VOLDOWN"},   "KC_LOCKING_CAPS":{"name":"KC_LOCKING_CAPS"},        "KC_LOCKING_NUM":{"name":"KC_LOCKING_NUM"},         "KC_LOCKING_SCROLL":{"name":"KC_LOCKING_SCROLL"},      "KC_KP_COMMA":{"name":"KC_KP_COMMA"},   "KC_KP_EQUAL_AS400":{"name":"KC_KP_EQUAL_AS400"},      "KC_INT1":{"name":"KC_INT1"},   "KC_INT2":{"name":"KC_INT2"},   "KC_INT3":{"name":"KC_INT3"},   "KC_INT4":{"name":"KC_INT4"},   "KC_INT5":{"name":"KC_INT5"},   "KC_INT6":{"name":"KC_INT6"},   "KC_INT7":{"name":"KC_INT7"},   "KC_INT8":{"name":"KC_INT8"},   "KC_INT9":{"name":"KC_INT9"},   "KC_LANG1":{"name":"KC_LANG1"},            "KC_LANG2":{"name":"KC_LANG2"},   "KC_LANG3":{"name":"KC_LANG3"},   "KC_LANG4":{"name":"KC_LANG4"},   "KC_LANG5":{"name":"KC_LANG5"},   "KC_LANG6":{"name":"KC_LANG6"},   "KC_LANG7":{"name":"KC_LANG7"},   "KC_LANG8":{"name":"KC_LANG8"},   "KC_LANG9":{"name":"KC_LANG9"},   "KC_ALT_ERASE":{"name":"KC_ALT_ERASE"},   "KC_SYSREQ":{"name":"KC_SYSREQ"},   "KC_CANCEL":{"name":"KC_CANCEL"},   "KC_CLEAR":{"name":"KC_CLEAR"},   "KC_PRIOR":{"name":"KC_PRIOR"},   "KC_RETURN":{"name":"KC_RETURN"},   "KC_SEPARATOR":{"name":"KC_SEPARATOR"},   "KC_OUT":{"name":"KC_OUT"},                 "KC_OPER":{"name":"KC_OPER"},   "KC_CLEAR_AGAIN":{"name":"KC_CLEAR_AGAIN"},   "KC_CRSEL":{"name":"KC_CRSEL"},   "KC_EXSEL":{"name":"KC_EXSEL"},               "KC_KP_00":{ "name":"KC_KP_00"},               "KC_KP_000":{"name":"KC_KP_000"},   "KC_THOUSANDS_SEPARATOR":{"name":"KC_THOUSANDS_SEPARATOR"},   "KC_DECIMAL_SEPARATOR":{"name":"KC_DECIMAL_SEPARATOR"},   "KC_CURRENCY_UNIT":{"name":"KC_CURRENCY_UNIT"},   "KC_CURRENCY_SUB_UNIT":{"name":"KC_CURRENCY_SUB_UNIT"},   "KC_KP_LPAREN":{"name":"KC_KP_LPAREN"},   "KC_KP_RPAREN":{"name":"KC_KP_RPAREN"},   "KC_KP_LCBRACKET":{"name":"KC_KP_LCBRACKET"},        "KC_KP_RCBRACKET":{"name":"KC_KP_RCBRACKET"},     
        "KC_KP_TAB":{"name":"KC_KP_TAB"},   "KC_KP_BSPACE":{"name":"KC_KP_BSPACE"},   "KC_KP_A":{"name":"KC_KP_A"},   "KC_KP_B":{"name":"KC_KP_B"},   "KC_KP_C":{"name":"KC_KP_C"},   "KC_KP_D":{"name":"KC_KP_D"},   "KC_KP_E":{"name":"KC_KP_E"},                "KC_KP_F":{"name":"KC_KP_F"},   "KC_KP_XOR":{"name":"KC_KP_XOR"},   "KC_KP_HAT":{"name":"KC_KP_HAT"},   "KC_KP_PERC":{"name":"KC_KP_PERC"},   "KC_KP_LT":{"name":"KC_KP_LT"},   "KC_KP_GT":{"name":"KC_KP_GT"},   "KC_KP_AND":{"name":"KC_KP_AND"},   "KC_KP_LAZYAND":{"name":"KC_KP_LAZYAND"},   "KC_KP_OR":{"name":"KC_KP_OR"},   "KC_KP_LAZYOR":{"name":"KC_KP_LAZYOR"},   "KC_KP_COLON":{"name":"KC_KP_COLON"},   "KC_KP_HASH":{"name":"KC_KP_HASH"},   "KC_KP_SPACE":{"name":"KC_KP_SPACE"},   "KC_KP_ATMARK":{"name":"KC_KP_ATMARK"},   "KC_KP_EXCLAMATION":{"name":"KC_KP_EXCLAMATION"},   "KC_KP_MEM_STORE":{"name":"KC_KP_MEM_STORE"},        "KC_KP_MEM_RECALL":{"name":"KC_KP_MEM_RECALL"},   "KC_KP_MEM_CLEAR":{"name":"KC_KP_MEM_CLEAR"},   "KC_KP_MEM_ADD":{"name":"KC_KP_MEM_ADD"},   "KC_KP_MEM_SUB":{"name":"KC_KP_MEM_SUB"},   "KC_KP_MEM_MUL":{"name":"KC_KP_MEM_MUL"},   "KC_KP_MEM_DIV":{"name":"KC_KP_MEM_DIV"},   "KC_KP_PLUS_MINUS":{"name":"KC_KP_PLUS_MINUS"},   "KC_KP_CLEAR":{"name":"KC_KP_CLEAR"},   "KC_KP_CLEAR_ENTRY":{"name":"KC_KP_CLEAR_ENTRY"},   "KC_KP_BINARY":{"name":"KC_KP_BINARY"},   "KC_KP_OCTAL":{"name":"KC_KP_OCTAL"},   "KC_KP_DECIMAL":{"name":"KC_KP_DECIMAL"},   "KC_KP_HEXADECIMAL":{"name":"KC_KP_HEXADECIMAL"},      "KC_LCTRL":{ "name":"KC_LCTRL"},              "KC_LSHIFT":{"name":"KC_LSHIFT"},   "KC_LALT":{"name":"KC_LALT"},   "KC_LGUI":{"name":"KC_LGUI"},   "KC_RCTRL":{"name":"KC_RCTRL"},   "KC_RSHIFT":{"name":"KC_RSHIFT"},   "KC_RALT":{"name":"KC_RALT"},   "KC_RGUI":{"name":"KC_RGUI"},   "KC_SYSTEM_POWER":{ "name":"KC_SYSTEM_POWER"},        "KC_SYSTEM_SLEEP":{"name":"KC_SYSTEM_SLEEP"},   "KC_SYSTEM_WAKE":{"name":"KC_SYSTEM_WAKE"},   "KC_AUDIO_MUTE":{"name":"KC_AUDIO_MUTE"},   "KC_AUDIO_VOL_UP":{"name":"KC_AUDIO_VOL_UP"},   "KC_AUDIO_VOL_DOWN":{"name":"KC_AUDIO_VOL_DOWN"},   "KC_MEDIA_NEXT_TRACK":{"name":"KC_MEDIA_NEXT_TRACK"},   "KC_MEDIA_PREV_TRACK":{"name":"KC_MEDIA_PREV_TRACK"},   "KC_MEDIA_STOP":{"name":"KC_MEDIA_STOP"},   "KC_MEDIA_PLAY_PAUSE":{"name":"KC_MEDIA_PLAY_PAUSE"},   "KC_MEDIA_SELECT":{"name":"KC_MEDIA_SELECT"},   "KC_MEDIA_EJECT":{"name":"KC_MEDIA_EJECT"},   "KC_MAIL":{"name":"KC_MAIL"},   "KC_CALCULATOR":{"name":"KC_CALCULATOR"},   "KC_MY_COMPUTER":{"name":"KC_MY_COMPUTER"},   "KC_WWW_SEARCH":{"name":"KC_WWW_SEARCH"},   "KC_WWW_HOME":{"name":"KC_WWW_HOME"},   "KC_WWW_BACK":{"name":"KC_WWW_BACK"},   "KC_WWW_FORWARD":{"name":"KC_WWW_FORWARD"},   "KC_WWW_STOP":{"name":"KC_WWW_STOP"},   "KC_WWW_REFRESH":{"name":"KC_WWW_REFRESH"},   "KC_WWW_FAVORITES":{"name":"KC_WWW_FAVORITES"},       "KC_FN0":{ "name":"KC_FN0"},                 "KC_FN1":{"name":"KC_FN1"},   "KC_FN2":{"name":"KC_FN2"},   "KC_FN3":{"name":"KC_FN3"},   "KC_FN4":{"name":"KC_FN4"},   "KC_FN5":{"name":"KC_FN5"},   "KC_FN6":{"name":"KC_FN6"},   "KC_FN7":{"name":"KC_FN7"},   "KC_FN8":{"name":"KC_FN8"},   "KC_FN9":{"name":"KC_FN9"},   "KC_FN10":{"name":"KC_FN10"},   "KC_FN11":{"name":"KC_FN11"},   "KC_FN12":{"name":"KC_FN12"},   "KC_FN13":{"name":"KC_FN13"},   "KC_FN14":{"name":"KC_FN14"},   "KC_FN15":{"name":"KC_FN15"},   "KC_FN16":{ "name":"KC_FN16"},                "KC_FN17":{"name":"KC_FN17"},   "KC_FN18":{"name":"KC_FN18"},   "KC_FN19":{"name":"KC_FN19"},   "KC_FN20":{"name":"KC_FN20"},   "KC_FN21":{"name":"KC_FN21"},   "KC_FN22":{"name":"KC_FN22"},   "KC_FN23":{"name":"KC_FN23"},   "KC_FN24":{"name":"KC_FN24"},   "KC_FN25":{"name":"KC_FN25"},   "KC_FN26":{"name":"KC_FN26"},   "KC_FN27":{"name":"KC_FN27"},   "KC_FN28":{"name":"KC_FN28"},   "KC_FN29":{"name":"KC_FN29"},   "KC_FN30":{"name":"KC_FN30"},   "KC_FN31":{"name":"KC_FN31"},                "KC_MS_UP":{ "name":"KC_MS_UP"},               "KC_MS_DOWN":{"name":"KC_MS_DOWN"},   "KC_MS_LEFT":{"name":"KC_MS_LEFT"},   "KC_MS_RIGHT":{"name":"KC_MS_RIGHT"},   "KC_MS_BTN1":{"name":"KC_MS_BTN1"},   "KC_MS_BTN2":{"name":"KC_MS_BTN2"},   "KC_MS_BTN3":{"name":"KC_MS_BTN3"},   "KC_MS_BTN4":{"name":"KC_MS_BTN4"},   "KC_MS_BTN5":{"name":"KC_MS_BTN5"},             "KC_MS_WH_UP":{"name":"KC_MS_WH_UP"},   "KC_MS_WH_DOWN":{"name":"KC_MS_WH_DOWN"},   "KC_MS_WH_LEFT":{"name":"KC_MS_WH_LEFT"},   "KC_MS_WH_RIGHT":{"name":"KC_MS_WH_RIGHT"},        "KC_MS_ACCEL0":{"name":"KC_MS_ACCEL0"},   "KC_MS_ACCEL1":{"name":"KC_MS_ACCEL1"},   "KC_MS_ACCEL2":{ "name":"KC_MS_ACCEL2"}  };      

  //  contextMenuItems._TEENSY.name = "Teensy Bootloader";
  //  contextMenuItems._LAYER_0.name = "Clear Layer Stack";
    contextMenuItems.KC_NO.name = "Transparent";
    contextMenuItems.KC_NO.disabled = function (key, opt) {
      return parseInt($activeKey.closest("svg").data("id")) == 0;
    };
    // start context menu
    $.contextMenu({
      selector:"#svg-container",
      trigger:"none",
      callback:function (key, options) {
        if (key == "Clear") {
          set_key_text($activeKey, null);
        } else {
          var key_data = get_key_data_by_const(key);
          if (key_data != null) {
            set_key_text($activeKey, key_data);
          }
        }
      },
      events:{
        hide:function (opt) {
          set_active_key($activeKey, false, null)
        }
      },
      items:contextMenuItems
    });

    // operations
    $("#download").click(function () {
      console.log($("#source").is(":checked"));
      var $button = $(this);
      toggleButton($button, "Compiling...");
      $.post("/api/ergodox", {layers:layers, action:"compile", source:$("#source").is(":checked") ? 1 : 0},function (data) {
        if (data.hasOwnProperty("file")) {
          $("#download-frame").attr("src", "https://s3.amazonaws.com/ergodox/" + data.file);
        }
      }, "json").always(function () {
          toggleButton($button);
        });
        });
    // $("#source").change(function () {
    //   if (this.checked) $("#download").text($("#download").text().replace(".hex", ".zip"));
    //   else $("#download").text($("#download").text().replace(".zip", ".hex"));
    // });
    $("#share").click(function () {
      var $button = $(this);
      toggleButton($button, "Linking...");
      $.post("/api/ergodox", {layers:layers, action:"share"},function (data) {
        var tpl = compile("tpl-share");
        $.colorbox({
          html:tpl,
          close:"",
          onComplete:function () {
            $("#cboxContent").find('textarea').text(data.url);
            $("#cboxContent").find('textarea').first().focus().select();
          }
        });
      }, "json").always(function () {
          toggleButton($button);
        });
    });
    $("#load").click(function () {
      $.get("/api/ergodox", {action:"list"}, function (data) {
        var tpl = compile("tpl-load");
        $.colorbox({
          html:tpl,
          close:"",
          onComplete:function () {
            var tpl_option = compile("tpl-load-option");
            for (var i = 0; i < data.length; i++) {
              $("#cboxContent").find("select").append(tpl_option(data[i]));
            }
            $("#cboxContent").find('.form-cancel').click(function (e) {
              e.preventDefault();
              $.colorbox.close();
            });
            $("#cboxContent").find('.btn-submit').click(function (e) {
              e.preventDefault();
              $.get("/api/ergodox", {action:"load", data_id:$("#cboxContent").find("select").val()}, loadLayerJson, 'json').always(function () {
                $.colorbox.close();
              });
            })
          }
        });
      }, "json");
    });
    $("#defaults").click(function () {
      var tpl = compile("tpl-defaults");
      $.colorbox({
        html:tpl,
        close:"",
        onComplete:function () {
          $("#cboxContent").find('.form-cancel').click(function (e) {
            e.preventDefault();
            $.colorbox.close();
          });
          $("#cboxContent").find('.btn-submit').click(function (e) {
            e.preventDefault();
            $.get("/api/ergodox", {action:"defaults", data_id:$("#cboxContent").find("select").val()}, loadLayerJson, 'json').always(function () {
              $.colorbox.close();
            });
          })
        }
      });
    });
    function pad (str, max) {
  str = str.toString();
  return str.length < max ? pad("0" + str, max) : str;
}
    $("#save").click(function () {
    	var text = "                                                            \
    /* left hand, spatial positions */                          \
    k00,k01,k02,k03,k04,k05,k06,                                \
    k10,k11,k12,k13,k14,k15,k16,                                \
    k20,k21,k22,k23,k24,k25,                                    \
    k30,k31,k32,k33,k34,k35,k36,                                \
    k40,k41,k42,k43,k44,                                        \
                            k55,k56,                            \
                                k54,                            \
                        k53,k52,k51,                            \
                                                                \
    /* right hand, spatial positions */                         \
        k07,k08,k09,k0A,k0B,k0C,k0D,                            \
        k17,k18,k19,k1A,k1B,k1C,k1D,                            \
            k28,k29,k2A,k2B,k2C,k2D,                            \
        k37,k38,k39,k3A,k3B,k3C,k3D,                            \
                k49,k4A,k4B,k4C,k4D,                            \
    k57,k58,                                                    \
    k59,                                                        \
    k5C,k5B,k5A )    ";
 
    	// initialize layers array (10 layers)
 	


 for (var i = 0; i < 1; i++) {
      var $layer = $('#l-' + i);
      for (var j = 0; j < layers[i].length; j++) {
        var $overlay = $layer.find('.o-' + j);
        if ($overlay.length > 0) {
          var key_data = get_key_data_by_const(layers[i][j]);
           
          if(key_data){
          		text = text.replace("k" + pad((j-1).toString(16), 2), key_data);
          		console.log(j, j.toString(16));
          	}
      		else
      			text = text.replace("k" + pad((j-1).toString(16), 2), key_data);
        }
      }
      $("#source").text(text) ;


      // $.get("/api/ergodox", {action:"list"}, function (data) {
      //   var tpl = compile("tpl-save");
      //   $.colorbox({
      //     html:tpl,
      //     close:"",
      //     onComplete:function () {
      //       var tpl_option = compile("tpl-load-option");
      //       $("#cboxContent").find("select").append(tpl_option);
      //       for (var i = 0; i < data.length; i++) {
      //         $("#cboxContent").find("select").append(tpl_option(data[i]));
      //         $("#cboxContent").find('input').first().focus().select();
      //       }
      //       $("#cboxContent").find("select").change(function () {
      //         $("#cboxContent").find("input").val("")
      //       });
      //       $("#cboxContent").find("input").change(function () {
      //         $("#cboxContent").find("select").val("")
      //       });
      //       $("#cboxContent").find('.form-cancel').click(function (e) {
      //         e.preventDefault();
      //         $.colorbox.close();
      //       });
      //       $("#cboxContent").find('.btn-submit').click(function (e) {
      //         e.preventDefault();
      //         var $form = $(this).closest("form");
      //         $.post("/api/ergodox", {layers:layers, action:"save", data_id:$form.find("select").val(), data_name:$form.find("input").val()}).always(function () {
      //           $.colorbox.close();
      //         });
      //       })
      //     }
      //   });
      // }, "json");
    }
});
    $("#load-more").click(function () {
      $(this).hide();
      for (var i = 3; i < 10; i++) $("#lb-" + i).removeClass("h");
    });

    // load sharing data
    });
</script>
 
  <title>keys
  </title>
</head>
<body class="signed_out_page_page">
<button id="save"></button>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<div id="tab-container">
  <div id="tab-configurator" class="">
    <div>
      
      </div>
            <div id="svg-container">
                <div id="lb-0" class="">
          <h2>Layer 0:</h2>
          <svg width="990" height="400" data-id="0" id="l-0" xmlns:svg="http://www.w3.org/2000/svg">
            <g>
            <!-- reorder these... -->
                            <rect class="k k-1" width="72.9" height="48.6" x="2.30931" y="29.53557" transform=""></rect>
              <text class="t t-1" x="38.75931" y="57.83557" transform=""></text>
              <rect class="o o-1" data-id="1" width="72.9" height="48.6" x="2.30931" y="29.53557" transform=""></rect>
                            <rect class="k k-2" width="48.6" height="48.6" x="78.75306" y="29.53557" transform=""></rect>
              <text class="t t-2" x="103.05306" y="57.83557" transform=""></text>
              <rect class="o o-2" data-id="2" width="48.6" height="48.6" x="78.75306" y="29.53557" transform=""></rect>
                            <rect class="k k-3" width="48.6" height="48.6" x="130.18806" y="20.95632" transform=""></rect>
              <text class="t t-3" x="154.48806" y="49.25632" transform=""></text>
              <rect class="o o-3" data-id="3" width="48.6" height="48.6" x="130.18806" y="20.95632" transform=""></rect>
                            <rect class="k k-4" width="48.6" height="48.6" x="181.62306" y="16.64253" transform=""></rect>
              <text class="t t-4" x="205.92306" y="44.94253" transform=""></text>
              <rect class="o o-4" data-id="4" width="48.6" height="48.6" x="181.62306" y="16.64253" transform=""></rect>
                            <rect class="k k-5" width="48.6" height="48.6" x="233.05806" y="20.95632" transform=""></rect>
              <text class="t t-5" x="257.35806" y="49.25632" transform=""></text>
              <rect class="o o-5" data-id="5" width="48.6" height="48.6" x="233.05806" y="20.95632" transform=""></rect>
                            <rect class="k k-6" width="48.6" height="48.6" x="284.49306" y="24.39207" transform=""></rect>
              <text class="t t-6" x="308.79306" y="52.69207" transform=""></text>
              <rect class="o o-6" data-id="6" width="48.6" height="48.6" x="284.49306" y="24.39207" transform=""></rect>
                            <rect class="k k-10" width="48.6" height="48.6" x="335.92806" y="24.39207" transform=""></rect>
              <text class="t t-10" x="360.22806" y="52.69207" transform=""></text>
              <rect class="o o-10" data-id="10" width="48.6" height="48.6" x="335.92806" y="24.39207" transform=""></rect>
                            <rect class="k k-8" width="72.9" height="48.6" x="2.30931" y="80.96382" transform=""></rect>
              <text class="t t-8" x="38.75931" y="109.26382" transform=""></text>
              <rect class="o o-8" data-id="8" width="72.9" height="48.6" x="2.30931" y="80.96382" transform=""></rect>
                            <rect class="k k-11" width="48.6" height="48.6" x="78.75306" y="80.96382" transform=""></rect>
              <text class="t t-11" x="103.05306" y="109.26382" transform=""></text>
              <rect class="o o-11" data-id="11" width="48.6" height="48.6" x="78.75306" y="80.96382" transform=""></rect>
                            <rect class="k k-12" width="48.6" height="48.6" x="130.18806" y="72.39132" transform=""></rect>
              <text class="t t-12" x="154.48806" y="100.69132" transform=""></text>
              <rect class="o o-12" data-id="12" width="48.6" height="48.6" x="130.18806" y="72.39132" transform=""></rect>
                            <rect class="k k-13" width="48.6" height="48.6" x="181.62306" y="68.07753" transform=""></rect>
              <text class="t t-13" x="205.92306" y="96.37753" transform=""></text>
              <rect class="o o-13" data-id="13" width="48.6" height="48.6" x="181.62306" y="68.07753" transform=""></rect>
                           <rect class="k k-14" width="48.6" height="48.6" x="233.05806" y="72.39132" transform=""></rect>
              <text class="t t-14" x="257.35806" y="100.69132" transform=""></text>
              <rect class="o o-14" data-id="14" width="48.6" height="48.6" x="233.05806" y="72.39132" transform=""></rect>
                            <rect class="k k-15" width="48.6" height="48.6" x="284.49306" y="75.82032" transform=""></rect>
              <text class="t t-15" x="308.79306" y="104.12032" transform=""></text>
              <rect class="o o-15" data-id="15" width="48.6" height="48.6" x="284.49306" y="75.82032" transform=""></rect>
                            <rect class="k k-16" width="48.6" height="72.9" x="335.92806" y="76.52907" transform=""></rect>
              <text class="t t-16" x="360.22806" y="116.97907" transform=""></text>
              <rect class="o o-16" data-id="16" width="48.6" height="72.9" x="335.92806" y="76.52907" transform=""></rect>
                            <rect class="k k-15" width="72.9" height="48.6" x="2.30931" y="132.39882" transform=""></rect>
              <text class="t t-15" x="38.75931" y="160.69882" transform=""></text>
              <rect class="o o-15" data-id="15" width="72.9" height="48.6" x="2.30931" y="132.39882" transform=""></rect>
                            <rect class="k k-16" width="48.6" height="48.6" x="78.75306" y="132.39882" transform=""></rect>
              <text class="t t-16" x="103.05306" y="160.69882" transform=""></text>
              <rect class="o o-16" data-id="16" width="48.6" height="48.6" x="78.75306" y="132.39882" transform=""></rect>
                            <rect class="k k-17" width="48.6" height="48.6" x="130.18806" y="123.82632" transform=""></rect>
              <text class="t t-17" x="154.48806" y="152.12632" transform=""></text>
              <rect class="o o-17" data-id="17" width="48.6" height="48.6" x="130.18806" y="123.82632" transform=""></rect>
                            <rect class="k k-18" width="48.6" height="48.6" x="181.62306" y="119.51253" transform=""></rect>
              <text class="t t-18" x="205.92306" y="147.81253" transform=""></text>
              <rect class="o o-18" data-id="18" width="48.6" height="48.6" x="181.62306" y="119.51253" transform=""></rect>
                            <rect class="k k-19" width="48.6" height="48.6" x="233.05806" y="123.82632" transform=""></rect>
              <text class="t t-19" x="257.35806" y="152.12632" transform=""></text>
              <rect class="o o-19" data-id="19" width="48.6" height="48.6" x="233.05806" y="123.82632" transform=""></rect>
                            <rect class="k k-20" width="48.6" height="48.6" x="284.49306" y="127.25532" transform=""></rect>
              <text class="t t-20" x="308.79306" y="155.55532" transform=""></text>
              <rect class="o o-20" data-id="20" width="48.6" height="48.6" x="284.49306" y="127.25532" transform=""></rect>
                            <rect class="k k-21" width="72.9" height="48.6" x="2.30931" y="183.83382" transform=""></rect>
              <text class="t t-21" x="38.75931" y="212.13382" transform=""></text>
              <rect class="o o-21" data-id="21" width="72.9" height="48.6" x="2.30931" y="183.83382" transform=""></rect>
                            <rect class="k k-22" width="48.6" height="48.6" x="78.75306" y="183.83382" transform=""></rect>
              <text class="t t-22" x="103.05306" y="212.13382" transform=""></text>
              <rect class="o o-22" data-id="22" width="48.6" height="48.6" x="78.75306" y="183.83382" transform=""></rect>
                            <rect class="k k-23" width="48.6" height="48.6" x="130.18806" y="175.26132" transform=""></rect>
              <text class="t t-23" x="154.48806" y="203.56132" transform=""></text>
              <rect class="o o-23" data-id="23" width="48.6" height="48.6" x="130.18806" y="175.26132" transform=""></rect>
                            <rect class="k k-24" width="48.6" height="48.6" x="181.62306" y="170.94753" transform=""></rect>
              <text class="t t-24" x="205.92306" y="199.24753" transform=""></text>
              <rect class="o o-24" data-id="24" width="48.6" height="48.6" x="181.62306" y="170.94753" transform=""></rect>
                            <rect class="k k-25" width="48.6" height="48.6" x="233.05806" y="175.26132" transform=""></rect>
              <text class="t t-25" x="257.35806" y="203.56132" transform=""></text>
              <rect class="o o-25" data-id="25" width="48.6" height="48.6" x="233.05806" y="175.26132" transform=""></rect>
                            <rect class="k k-26" width="48.6" height="48.6" x="284.49306" y="178.69032" transform=""></rect>
              <text class="t t-26" x="308.79306" y="206.99032" transform=""></text>
              <rect class="o o-26" data-id="26" width="48.6" height="48.6" x="284.49306" y="178.69032" transform=""></rect>
                            <rect class="k k-27" width="48.6" height="72.9" x="335.92806" y="153.68157" transform=""></rect>
              <text class="t t-27" x="360.22806" y="194.13157" transform=""></text>
              <rect class="o o-27" data-id="27" width="48.6" height="72.9" x="335.92806" y="153.68157" transform=""></rect>
                            <rect class="k k-28" width="48.6" height="48.6" x="27.31806" y="235.26882" transform=""></rect>
              <text class="t t-28" x="51.61806" y="263.56882" transform=""></text>
              <rect class="o o-28" data-id="28" width="48.6" height="48.6" x="27.31806" y="235.26882" transform=""></rect>
                            <rect class="k k-29" width="48.6" height="48.6" x="78.75306" y="235.26882" transform=""></rect>
              <text class="t t-29" x="103.05306" y="263.56882" transform=""></text>
              <rect class="o o-29" data-id="29" width="48.6" height="48.6" x="78.75306" y="235.26882" transform=""></rect>
                            <rect class="k k-30" width="48.6" height="48.6" x="130.18806" y="226.69632" transform=""></rect>
              <text class="t t-30" x="154.48806" y="254.99632" transform=""></text>
              <rect class="o o-30" data-id="30" width="48.6" height="48.6" x="130.18806" y="226.69632" transform=""></rect>
                            <rect class="k k-31" width="48.6" height="48.6" x="181.62306" y="222.38253" transform=""></rect>
              <text class="t t-31" x="205.92306" y="250.68253" transform=""></text>
              <rect class="o o-31" data-id="31" width="48.6" height="48.6" x="181.62306" y="222.38253" transform=""></rect>
                            <rect class="k k-32" width="48.6" height="48.6" x="233.05806" y="226.69632" transform=""></rect>
              <text class="t t-32" x="257.35806" y="254.99632" transform=""></text>
              <rect class="o o-32" data-id="32" width="48.6" height="48.6" x="233.05806" y="226.69632" transform=""></rect>
                            <rect class="k k-33" width="48.6" height="48.6" x="391.08015" y="213.71391" transform="rotate(25,415.38015,238.01391)"></rect>
              <text class="t t-33" x="415.38015" y="242.01391" transform="rotate(25,415.38015,238.01391)"></text>
              <rect class="o o-33" data-id="33" width="48.6" height="48.6" x="391.08015" y="213.71391" transform="rotate(25,415.38015,238.01391)"></rect>
                            <rect class="k k-34" width="48.6" height="48.6" x="437.69403" y="235.44702" transform="rotate(25,461.99403,259.74702)"></rect>
              <text class="t t-34" x="461.99403" y="263.74702" transform="rotate(25,461.99403,259.74702)"></text>
              <rect class="o o-34" data-id="34" width="48.6" height="48.6" x="437.69403" y="235.44702" transform="rotate(25,461.99403,259.74702)"></rect>
                            <rect class="k k-37" width="48.6" height="48.6" x="415.96092" y="282.0609" transform="rotate(25,440.26092,306.3609)"></rect>
              <text class="t t-37" x="440.26092" y="310.3609" transform="rotate(25,440.26092,306.3609)"></text>
              <rect class="o o-37" data-id="37" width="48.6" height="48.6" x="415.96092" y="282.0609" transform="rotate(25,440.26092,306.3609)"></rect>
                            <rect class="k k-38" width="48.6" height="97.2" x="311.8635" y="237.59838" transform="rotate(25,336.1635,286.19838)"></rect>
              <text class="t t-38" x="336.1635" y="290.19838" transform="rotate(25,336.1635,286.19838)"></text>
              <rect class="o o-38" data-id="38" width="48.6" height="97.2" x="311.8635" y="237.59838" transform="rotate(25,336.1635,286.19838)"></rect>
                            <rect class="k k-39" width="48.6" height="97.2" x="358.47738" y="259.33824" transform="rotate(25,382.77738,307.93824)"></rect>
              <text class="t t-39" x="382.77738" y="311.93824" transform="rotate(25,382.77738,307.93824)"></text>
              <rect class="o o-39" data-id="39" width="48.6" height="97.2" x="358.47738" y="259.33824" transform="rotate(25,382.77738,307.93824)"></rect>
                            <rect class="k k-40" width="48.6" height="48.6" x="394.22106" y="328.68153" transform="rotate(25,418.52106,352.98153)"></rect>
              <text class="t t-40" x="418.52106" y="356.98153" transform="rotate(25,418.52106,352.98153)"></text>
              <rect class="o o-40" data-id="40" width="48.6" height="48.6" x="394.22106" y="328.68153" transform="rotate(25,418.52106,352.98153)"></rect>
                            <rect class="k k-47" width="72.9" height="48.6" x="915.69069" y="29.53557" transform=""></rect>
              <text class="t t-47" x="952.14069" y="57.83557" transform=""></text>
              <rect class="o o-47" data-id="47" width="72.9" height="48.6" x="915.69069" y="29.53557" transform=""></rect>
                            <rect class="k k-46" width="48.6" height="48.6" x="863.54694" y="29.53557" transform=""></rect>
              <text class="t t-46" x="887.84694" y="57.83557" transform=""></text>
              <rect class="o o-46" data-id="46" width="48.6" height="48.6" x="863.54694" y="29.53557" transform=""></rect>
                            <rect class="k k-45" width="48.6" height="48.6" x="812.11194" y="20.95632" transform=""></rect>
              <text class="t t-45" x="836.41194" y="49.25632" transform=""></text>
              <rect class="o o-45" data-id="45" width="48.6" height="48.6" x="812.11194" y="20.95632" transform=""></rect>
                            <rect class="k k-44" width="48.6" height="48.6" x="760.67694" y="16.64253" transform=""></rect>
              <text class="t t-44" x="784.97694" y="44.94253" transform=""></text>
              <rect class="o o-44" data-id="44" width="48.6" height="48.6" x="760.67694" y="16.64253" transform=""></rect>
                            <rect class="k k-43" width="48.6" height="48.6" x="709.24194" y="20.95632" transform=""></rect>
              <text class="t t-43" x="733.54194" y="49.25632" transform=""></text>
              <rect class="o o-43" data-id="43" width="48.6" height="48.6" x="709.24194" y="20.95632" transform=""></rect>
                            <rect class="k k-42" width="48.6" height="48.6" x="657.80694" y="24.39207" transform=""></rect>
              <text class="t t-42" x="682.10694" y="52.69207" transform=""></text>
              <rect class="o o-42" data-id="42" width="48.6" height="48.6" x="657.80694" y="24.39207" transform=""></rect>
                            <rect class="k k-41" width="48.6" height="48.6" x="606.37194" y="24.39207" transform=""></rect>
              <text class="t t-41" x="630.67194" y="52.69207" transform=""></text>
              <rect class="o o-41" data-id="41" width="48.6" height="48.6" x="606.37194" y="24.39207" transform=""></rect>
                            <rect class="k k-54" width="72.9" height="48.6" x="915.69069" y="80.96382" transform=""></rect>
              <text class="t t-54" x="952.14069" y="109.26382" transform=""></text>
              <rect class="o o-54" data-id="54" width="72.9" height="48.6" x="915.69069" y="80.96382" transform=""></rect>
                            <rect class="k k-53" width="48.6" height="48.6" x="863.54694" y="80.96382" transform=""></rect>
              <text class="t t-53" x="887.84694" y="109.26382" transform=""></text>
              <rect class="o o-53" data-id="53" width="48.6" height="48.6" x="863.54694" y="80.96382" transform=""></rect>
                            <rect class="k k-52" width="48.6" height="48.6" x="812.11194" y="72.39132" transform=""></rect>
              <text class="t t-52" x="836.41194" y="100.69132" transform=""></text>
              <rect class="o o-52" data-id="52" width="48.6" height="48.6" x="812.11194" y="72.39132" transform=""></rect>
                            <rect class="k k-51" width="48.6" height="48.6" x="760.67694" y="68.07753" transform=""></rect>
              <text class="t t-51" x="784.97694" y="96.37753" transform=""></text>
              <rect class="o o-51" data-id="51" width="48.6" height="48.6" x="760.67694" y="68.07753" transform=""></rect>
                            <rect class="k k-50" width="48.6" height="48.6" x="709.24194" y="72.39132" transform=""></rect>
              <text class="t t-50" x="733.54194" y="100.69132" transform=""></text>
              <rect class="o o-50" data-id="50" width="48.6" height="48.6" x="709.24194" y="72.39132" transform=""></rect>
                            <rect class="k k-49" width="48.6" height="48.6" x="657.80694" y="75.82032" transform=""></rect>
              <text class="t t-49" x="682.10694" y="104.12032" transform=""></text>
              <rect class="o o-49" data-id="49" width="48.6" height="48.6" x="657.80694" y="75.82032" transform=""></rect>
                            <rect class="k k-48" width="48.6" height="72.9" x="606.37194" y="76.52907" transform=""></rect>
              <text class="t t-48" x="630.67194" y="116.97907" transform=""></text>
              <rect class="o o-48" data-id="48" width="48.6" height="72.9" x="606.37194" y="76.52907" transform=""></rect>
                            <rect class="k k-60" width="72.9" height="48.6" x="915.69069" y="132.39882" transform=""></rect>
              <text class="t t-60" x="952.14069" y="160.69882" transform=""></text>
              <rect class="o o-60" data-id="60" width="72.9" height="48.6" x="915.69069" y="132.39882" transform=""></rect>
                            <rect class="k k-59" width="48.6" height="48.6" x="863.54694" y="132.39882" transform=""></rect>
              <text class="t t-59" x="887.84694" y="160.69882" transform=""></text>
              <rect class="o o-59" data-id="59" width="48.6" height="48.6" x="863.54694" y="132.39882" transform=""></rect>
                            <rect class="k k-58" width="48.6" height="48.6" x="812.11194" y="123.82632" transform=""></rect>
              <text class="t t-58" x="836.41194" y="152.12632" transform=""></text>
              <rect class="o o-58" data-id="58" width="48.6" height="48.6" x="812.11194" y="123.82632" transform=""></rect>
                            <rect class="k k-57" width="48.6" height="48.6" x="760.67694" y="119.51253" transform=""></rect>
              <text class="t t-57" x="784.97694" y="147.81253" transform=""></text>
              <rect class="o o-57" data-id="57" width="48.6" height="48.6" x="760.67694" y="119.51253" transform=""></rect>
                            <rect class="k k-56" width="48.6" height="48.6" x="709.24194" y="123.82632" transform=""></rect>
              <text class="t t-56" x="733.54194" y="152.12632" transform=""></text>
              <rect class="o o-56" data-id="56" width="48.6" height="48.6" x="709.24194" y="123.82632" transform=""></rect>
                            <rect class="k k-55" width="48.6" height="48.6" x="657.80694" y="127.25532" transform=""></rect>
              <text class="t t-55" x="682.10694" y="155.55532" transform=""></text>
              <rect class="o o-55" data-id="55" width="48.6" height="48.6" x="657.80694" y="127.25532" transform=""></rect>
                            <rect class="k k-67" width="72.9" height="48.6" x="915.69069" y="183.83382" transform=""></rect>
              <text class="t t-67" x="952.14069" y="212.13382" transform=""></text>
              <rect class="o o-67" data-id="67" width="72.9" height="48.6" x="915.69069" y="183.83382" transform=""></rect>
                            <rect class="k k-66" width="48.6" height="48.6" x="863.54694" y="183.83382" transform=""></rect>
              <text class="t t-66" x="887.84694" y="212.13382" transform=""></text>
              <rect class="o o-66" data-id="66" width="48.6" height="48.6" x="863.54694" y="183.83382" transform=""></rect>
                            <rect class="k k-65" width="48.6" height="48.6" x="812.11194" y="175.26132" transform=""></rect>
              <text class="t t-65" x="836.41194" y="203.56132" transform=""></text>
              <rect class="o o-65" data-id="65" width="48.6" height="48.6" x="812.11194" y="175.26132" transform=""></rect>
                            <rect class="k k-64" width="48.6" height="48.6" x="760.67694" y="170.94753" transform=""></rect>
              <text class="t t-64" x="784.97694" y="199.24753" transform=""></text>
              <rect class="o o-64" data-id="64" width="48.6" height="48.6" x="760.67694" y="170.94753" transform=""></rect>
                            <rect class="k k-63" width="48.6" height="48.6" x="709.24194" y="175.26132" transform=""></rect>
              <text class="t t-63" x="733.54194" y="203.56132" transform=""></text>
              <rect class="o o-63" data-id="63" width="48.6" height="48.6" x="709.24194" y="175.26132" transform=""></rect>
                            <rect class="k k-62" width="48.6" height="48.6" x="657.80694" y="178.69032" transform=""></rect>
              <text class="t t-62" x="682.10694" y="206.99032" transform=""></text>
              <rect class="o o-62" data-id="62" width="48.6" height="48.6" x="657.80694" y="178.69032" transform=""></rect>
                            <rect class="k k-61" width="48.6" height="72.9" x="606.37194" y="153.68157" transform=""></rect>
              <text class="t t-61" x="630.67194" y="194.13157" transform=""></text>
              <rect class="o o-61" data-id="61" width="48.6" height="72.9" x="606.37194" y="153.68157" transform=""></rect>
                            <rect class="k k-72" width="48.6" height="48.6" x="914.98194" y="235.26882" transform=""></rect>
              <text class="t t-72" x="939.28194" y="263.56882" transform=""></text>
              <rect class="o o-72" data-id="72" width="48.6" height="48.6" x="914.98194" y="235.26882" transform=""></rect>
                            <rect class="k k-71" width="48.6" height="48.6" x="863.54694" y="235.26882" transform=""></rect>
              <text class="t t-71" x="887.84694" y="263.56882" transform=""></text>
              <rect class="o o-71" data-id="71" width="48.6" height="48.6" x="863.54694" y="235.26882" transform=""></rect>
                            <rect class="k k-70" width="48.6" height="48.6" x="812.11194" y="226.69632" transform=""></rect>
              <text class="t t-70" x="836.41194" y="254.99632" transform=""></text>
              <rect class="o o-70" data-id="70" width="48.6" height="48.6" x="812.11194" y="226.69632" transform=""></rect>
                            <rect class="k k-69" width="48.6" height="48.6" x="760.67694" y="222.38253" transform=""></rect>
              <text class="t t-69" x="784.97694" y="250.68253" transform=""></text>
              <rect class="o o-69" data-id="69" width="48.6" height="48.6" x="760.67694" y="222.38253" transform=""></rect>
                            <rect class="k k-68" width="48.6" height="48.6" x="709.24194" y="226.69632" transform=""></rect>
              <text class="t t-68" x="733.54194" y="254.99632" transform=""></text>
              <rect class="o o-68" data-id="68" width="48.6" height="48.6" x="709.24194" y="226.69632" transform=""></rect>
                            <rect class="k k-74" width="48.6" height="48.6" x="551.21985" y="213.71391" transform="rotate(-25,575.51985,238.01391)"></rect>
              <text class="t t-74" x="575.51985" y="242.01391" transform="rotate(-25,575.51985,238.01391)"></text>
              <rect class="o o-74" data-id="74" width="48.6" height="48.6" x="551.21985" y="213.71391" transform="rotate(-25,575.51985,238.01391)"></rect>
                            <rect class="k k-73" width="48.6" height="48.6" x="504.60597" y="235.44702" transform="rotate(-25,528.90597,259.74702)"></rect>
              <text class="t t-73" x="528.90597" y="263.74702" transform="rotate(-25,528.90597,259.74702)"></text>
              <rect class="o o-73" data-id="73" width="48.6" height="48.6" x="504.60597" y="235.44702" transform="rotate(-25,528.90597,259.74702)"></rect>
                            <rect class="k k-75" width="48.6" height="48.6" x="526.33908" y="282.0609" transform="rotate(-25,550.63908,306.3609)"></rect>
              <text class="t t-75" x="550.63908" y="310.3609" transform="rotate(-25,550.63908,306.3609)"></text>
              <rect class="o o-75" data-id="75" width="48.6" height="48.6" x="526.33908" y="282.0609" transform="rotate(-25,550.63908,306.3609)"></rect>
                            <rect class="k k-80" width="48.6" height="97.2" x="630.4365" y="237.59838" transform="rotate(-25,654.7365,286.19838)"></rect>
              <text class="t t-80" x="654.7365" y="290.19838" transform="rotate(-25,654.7365,286.19838)"></text>
              <rect class="o o-80" data-id="80" width="48.6" height="97.2" x="630.4365" y="237.59838" transform="rotate(-25,654.7365,286.19838)"></rect>
                            <rect class="k k-79" width="48.6" height="97.2" x="583.82262" y="259.33824" transform="rotate(-25,608.12262,307.93824)"></rect>
              <text class="t t-79" x="608.12262" y="311.93824" transform="rotate(-25,608.12262,307.93824)"></text>
              <rect class="o o-79" data-id="79" width="48.6" height="97.2" x="583.82262" y="259.33824" transform="rotate(-25,608.12262,307.93824)"></rect>
                            <rect class="k k-78" width="48.6" height="48.6" x="548.07894" y="328.68153" transform="rotate(-25,572.37894,352.98153)"></rect>
              <text class="t t-78" x="572.37894" y="356.98153" transform="rotate(-25,572.37894,352.98153)"></text>
              <rect class="o o-78" data-id="78" width="48.6" height="48.6" x="548.07894" y="328.68153" transform="rotate(-25,572.37894,352.98153)"></rect>
                          </g>
          </svg>
        </div>
      
      </div>
    </div>
  </div>

  <div id="source"></div>
  </div>


</body>
</html>